<?php
$tdataaccounts=array();
	$tdataaccounts[".NumberOfChars"]=80; 
	$tdataaccounts[".ShortName"]="accounts";
	$tdataaccounts[".OwnerID"]="";
	$tdataaccounts[".OriginalTable"]="accounts";


	
//	field labels
$fieldLabelsaccounts = array();
if(mlang_getcurrentlang()=="English")
{
	$fieldLabelsaccounts["English"]=array();
	$fieldToolTipsaccounts["English"]=array();
	$fieldLabelsaccounts["English"]["id"] = "Id";
	$fieldToolTipsaccounts["English"]["id"] = "";
	$fieldLabelsaccounts["English"]["account_name"] = "Account Name";
	$fieldToolTipsaccounts["English"]["account_name"] = "";
	if (count($fieldToolTipsaccounts["English"])){
		$tdataaccounts[".isUseToolTips"]=true;
	}
}
if(mlang_getcurrentlang()=="Chinese (Hong Kong S.A.R.)")
{
	$fieldLabelsaccounts["Chinese (Hong Kong S.A.R.)"]=array();
	$fieldToolTipsaccounts["Chinese (Hong Kong S.A.R.)"]=array();
	$fieldLabelsaccounts["Chinese (Hong Kong S.A.R.)"]["id"] = "Id";
	$fieldToolTipsaccounts["Chinese (Hong Kong S.A.R.)"]["id"] = "";
	$fieldLabelsaccounts["Chinese (Hong Kong S.A.R.)"]["account_name"] = "Account Name";
	$fieldToolTipsaccounts["Chinese (Hong Kong S.A.R.)"]["account_name"] = "";
	if (count($fieldToolTipsaccounts["Chinese (Hong Kong S.A.R.)"])){
		$tdataaccounts[".isUseToolTips"]=true;
	}
}
if(mlang_getcurrentlang()=="Chinese (Taiwan)")
{
	$fieldLabelsaccounts["Chinese (Taiwan)"]=array();
	$fieldToolTipsaccounts["Chinese (Taiwan)"]=array();
	$fieldLabelsaccounts["Chinese (Taiwan)"]["id"] = "Id";
	$fieldToolTipsaccounts["Chinese (Taiwan)"]["id"] = "";
	$fieldLabelsaccounts["Chinese (Taiwan)"]["account_name"] = "Account Name";
	$fieldToolTipsaccounts["Chinese (Taiwan)"]["account_name"] = "";
	if (count($fieldToolTipsaccounts["Chinese (Taiwan)"])){
		$tdataaccounts[".isUseToolTips"]=true;
	}
}
if(mlang_getcurrentlang()=="French")
{
	$fieldLabelsaccounts["French"]=array();
	$fieldToolTipsaccounts["French"]=array();
	$fieldLabelsaccounts["French"]["id"] = "Id";
	$fieldToolTipsaccounts["French"]["id"] = "";
	$fieldLabelsaccounts["French"]["account_name"] = "Account Name";
	$fieldToolTipsaccounts["French"]["account_name"] = "";
	if (count($fieldToolTipsaccounts["French"])){
		$tdataaccounts[".isUseToolTips"]=true;
	}
}


	
	$tdataaccounts[".NCSearch"]=true;

	

$tdataaccounts[".shortTableName"] = "accounts";
$tdataaccounts[".nSecOptions"] = 0;
$tdataaccounts[".recsPerRowList"] = 1;	
$tdataaccounts[".tableGroupBy"] = "0";
$tdataaccounts[".mainTableOwnerID"] = "";
$tdataaccounts[".moveNext"] = 1;




$tdataaccounts[".showAddInPopup"] = false;

$tdataaccounts[".showEditInPopup"] = false;

$tdataaccounts[".showViewInPopup"] = false;


$tdataaccounts[".fieldsForRegister"] = array();

$tdataaccounts[".listAjax"] = false;

	$tdataaccounts[".audit"] = false;

	$tdataaccounts[".locking"] = false;
	
$tdataaccounts[".listIcons"] = true;
$tdataaccounts[".edit"] = true;
$tdataaccounts[".inlineEdit"] = true;
$tdataaccounts[".view"] = true;

$tdataaccounts[".exportTo"] = true;

$tdataaccounts[".printFriendly"] = true;

$tdataaccounts[".delete"] = true;

$tdataaccounts[".showSimpleSearchOptions"] = false;

$tdataaccounts[".showSearchPanel"] = true;


$tdataaccounts[".isUseAjaxSuggest"] = true;

$tdataaccounts[".rowHighlite"] = true;


// button handlers file names

$tdataaccounts[".addPageEvents"] = false;

$tdataaccounts[".arrKeyFields"][] = "id";

// use datepicker for search panel
$tdataaccounts[".isUseCalendarForSearch"] = false;

// use timepicker for search panel
$tdataaccounts[".isUseTimeForSearch"] = false;

$tdataaccounts[".isUseiBox"] = false;



$tdataaccounts[".isUseInlineAdd"] = true;

$tdataaccounts[".isUseInlineEdit"] = true;
$tdataaccounts[".isUseInlineJs"] = $tdataaccounts[".isUseInlineAdd"] || $tdataaccounts[".isUseInlineEdit"];

$tdataaccounts[".allSearchFields"] = array();

$tdataaccounts[".globSearchFields"][] = "id";
// do in this way, because combine functions array_unique and array_merge returns array with keys like 1,2, 4 etc
if (!in_array("id", $tdataaccounts[".allSearchFields"]))
{
	$tdataaccounts[".allSearchFields"][] = "id";	
}
$tdataaccounts[".globSearchFields"][] = "account_name";
// do in this way, because combine functions array_unique and array_merge returns array with keys like 1,2, 4 etc
if (!in_array("account_name", $tdataaccounts[".allSearchFields"]))
{
	$tdataaccounts[".allSearchFields"][] = "account_name";	
}


$tdataaccounts[".googleLikeFields"][] = "id";
$tdataaccounts[".googleLikeFields"][] = "account_name";



$tdataaccounts[".advSearchFields"][] = "id";
// do in this way, because combine functions array_unique and array_merge returns array with keys like 1,2, 4 etc
if (!in_array("id", $tdataaccounts[".allSearchFields"])) 
{
	$tdataaccounts[".allSearchFields"][] = "id";	
}
$tdataaccounts[".advSearchFields"][] = "account_name";
// do in this way, because combine functions array_unique and array_merge returns array with keys like 1,2, 4 etc
if (!in_array("account_name", $tdataaccounts[".allSearchFields"])) 
{
	$tdataaccounts[".allSearchFields"][] = "account_name";	
}

$tdataaccounts[".isTableType"] = "list";


	

$tdataaccounts[".isDisplayLoading"] = true;

$tdataaccounts[".isResizeColumns"] = true;


$tdataaccounts[".noRecordsFirstPage"] = true;



$tdataaccounts[".pageSize"] = 20;

$gstrOrderBy = "";
if(strlen($gstrOrderBy) && strtolower(substr($gstrOrderBy,0,8))!="order by")
	$gstrOrderBy = "order by ".$gstrOrderBy;
$tdataaccounts[".strOrderBy"] = $gstrOrderBy;
	
$tdataaccounts[".orderindexes"] = array();

$tdataaccounts[".sqlHead"] = "SELECT id,  account_name";
$tdataaccounts[".sqlFrom"] = "FROM accounts";
$tdataaccounts[".sqlWhereExpr"] = "";
$tdataaccounts[".sqlTail"] = "";




//fill array of records per page for list and report without group fields
$arrRPP = array();
$arrRPP[] = 10;
$arrRPP[] = 20;
$arrRPP[] = 30;
$arrRPP[] = 50;
$arrRPP[] = 100;
$arrRPP[] = 500;
$arrRPP[] = -1;
$tdataaccounts[".arrRecsPerPage"] = $arrRPP;

//fill array of groups per page for report with group fields
$arrGPP = array();
$arrGPP[] = 1;
$arrGPP[] = 3;
$arrGPP[] = 5;
$arrGPP[] = 10;
$arrGPP[] = 50;
$arrGPP[] = 100;
$arrGPP[] = -1;
$tdataaccounts[".arrGroupsPerPage"] = $arrGPP;

	$tableKeys = array();
	$tableKeys[] = "id";
	$tdataaccounts[".Keys"] = $tableKeys;

//	id
	$fdata = array();
	$fdata["strName"] = "id";
	$fdata["ownerTable"] = "accounts";
		$fdata["Label"]="Id"; 
	
		
		
	$fdata["FieldType"]= 3;
	
		$fdata["AutoInc"]=true;
	
			$fdata["UseiBox"] = false;
	
	$fdata["EditFormat"]= "Text field";
	$fdata["ViewFormat"]= "";
	
		
		
		
		
		$fdata["NeedEncode"]=true;
	
	$fdata["GoodName"]= "id";
	
		$fdata["FullName"]= "id";
	
		$fdata["IsRequired"]=true; 
	
		
		
		
		
				$fdata["Index"]= 1;
				$fdata["EditParams"]="";
			
		$fdata["bListPage"]=true; 
	
		
		
		
		
		$fdata["bViewPage"]=true; 
	
		$fdata["bAdvancedSearch"]=true; 
	
		$fdata["bPrinterPage"]=true; 
	
		$fdata["bExportPage"]=true; 
	
	//Begin validation
	$fdata["validateAs"] = array();
				$fdata["validateAs"]["basicValidate"][] = getJsValidatorName("Number");	
						$fdata["validateAs"]["basicValidate"][] = "IsRequired";
	
		//End validation
	
				$fdata["FieldPermissions"]=true;
	
		
				
		
		
		
			$tdataaccounts["id"]=$fdata;
//	account_name
	$fdata = array();
	$fdata["strName"] = "account_name";
	$fdata["ownerTable"] = "accounts";
		$fdata["Label"]="Account Name"; 
	
		
		
	$fdata["FieldType"]= 200;
	
		
			$fdata["UseiBox"] = false;
	
	$fdata["EditFormat"]= "Text field";
	$fdata["ViewFormat"]= "";
	
		
		
		
		
		$fdata["NeedEncode"]=true;
	
	$fdata["GoodName"]= "account_name";
	
		$fdata["FullName"]= "account_name";
	
		$fdata["IsRequired"]=true; 
	
		
		
		
		
				$fdata["Index"]= 2;
				$fdata["EditParams"]="";
			$fdata["EditParams"].= " maxlength=150";
		
		$fdata["bListPage"]=true; 
	
		$fdata["bAddPage"]=true; 
	
		$fdata["bInlineAdd"]=true; 
	
		$fdata["bEditPage"]=true; 
	
		$fdata["bInlineEdit"]=true; 
	
		$fdata["bViewPage"]=true; 
	
		$fdata["bAdvancedSearch"]=true; 
	
		$fdata["bPrinterPage"]=true; 
	
		$fdata["bExportPage"]=true; 
	
	//Begin validation
	$fdata["validateAs"] = array();
						$fdata["validateAs"]["basicValidate"][] = "IsRequired";
	
		//End validation
	
				$fdata["FieldPermissions"]=true;
	
		
				
		
		
		
			$tdataaccounts["account_name"]=$fdata;

	
$tables_data["accounts"]=&$tdataaccounts;
$field_labels["accounts"] = &$fieldLabelsaccounts;
$fieldToolTips["accounts"] = &$fieldToolTipsaccounts;

// -----------------start  prepare master-details data arrays ------------------------------//
// tables which are detail tables for current table (master)
$detailsTablesData["accounts"] = array();

	
// tables which are master tables for current table (detail)
$masterTablesData["accounts"] = array();

// -----------------end  prepare master-details data arrays ------------------------------//

require_once(getabspath("classes/sql.php"));










$proto674=array();
$proto674["m_strHead"] = "SELECT";
$proto674["m_strFieldList"] = "id,  account_name";
$proto674["m_strFrom"] = "FROM accounts";
$proto674["m_strWhere"] = "";
$proto674["m_strOrderBy"] = "";
$proto674["m_strTail"] = "";
$proto675=array();
$proto675["m_sql"] = "";
$proto675["m_uniontype"] = "SQLL_UNKNOWN";
	$obj = new SQLNonParsed(array(
	"m_sql" => ""
));

$proto675["m_column"]=$obj;
$proto675["m_contained"] = array();
$proto675["m_strCase"] = "";
$proto675["m_havingmode"] = "0";
$proto675["m_inBrackets"] = "0";
$proto675["m_useAlias"] = "0";
$obj = new SQLLogicalExpr($proto675);

$proto674["m_where"] = $obj;
$proto677=array();
$proto677["m_sql"] = "";
$proto677["m_uniontype"] = "SQLL_UNKNOWN";
	$obj = new SQLNonParsed(array(
	"m_sql" => ""
));

$proto677["m_column"]=$obj;
$proto677["m_contained"] = array();
$proto677["m_strCase"] = "";
$proto677["m_havingmode"] = "0";
$proto677["m_inBrackets"] = "0";
$proto677["m_useAlias"] = "0";
$obj = new SQLLogicalExpr($proto677);

$proto674["m_having"] = $obj;
$proto674["m_fieldlist"] = array();
						$proto679=array();
			$obj = new SQLField(array(
	"m_strName" => "id",
	"m_strTable" => "accounts"
));

$proto679["m_expr"]=$obj;
$proto679["m_alias"] = "";
$obj = new SQLFieldListItem($proto679);

$proto674["m_fieldlist"][]=$obj;
						$proto681=array();
			$obj = new SQLField(array(
	"m_strName" => "account_name",
	"m_strTable" => "accounts"
));

$proto681["m_expr"]=$obj;
$proto681["m_alias"] = "";
$obj = new SQLFieldListItem($proto681);

$proto674["m_fieldlist"][]=$obj;
$proto674["m_fromlist"] = array();
												$proto683=array();
$proto683["m_link"] = "SQLL_MAIN";
			$proto684=array();
$proto684["m_strName"] = "accounts";
$proto684["m_columns"] = array();
$proto684["m_columns"][] = "id";
$proto684["m_columns"][] = "account_name";
$obj = new SQLTable($proto684);

$proto683["m_table"] = $obj;
$proto683["m_alias"] = "";
$proto685=array();
$proto685["m_sql"] = "";
$proto685["m_uniontype"] = "SQLL_UNKNOWN";
	$obj = new SQLNonParsed(array(
	"m_sql" => ""
));

$proto685["m_column"]=$obj;
$proto685["m_contained"] = array();
$proto685["m_strCase"] = "";
$proto685["m_havingmode"] = "0";
$proto685["m_inBrackets"] = "0";
$proto685["m_useAlias"] = "0";
$obj = new SQLLogicalExpr($proto685);

$proto683["m_joinon"] = $obj;
$obj = new SQLFromListItem($proto683);

$proto674["m_fromlist"][]=$obj;
$proto674["m_groupby"] = array();
$proto674["m_orderby"] = array();
$obj = new SQLQuery($proto674);

$queryData_accounts = $obj;
$tdataaccounts[".sqlquery"] = $queryData_accounts;

$tableEvents["accounts"] = new eventsBase;

?>
